banner

LISTS TEST

This test will show me how well you

1) can quickly design code to a particular spec

2) manage your time

3) can utilize lists

Scoring

All program names, list names and variable names must be absolutely identical to those called for in the spec. One point will be deducted for any misspelled item.

One point will be deducted for any missing item called for in the spec.

One point will be deducted for each action called for in the spec that is not complete.

 

═════════════════════

If your position at your table is designated as 'blue':

Please write a program to the following specifics. YOU MUST use the names, variables and function names provided:

1) Create a program called "lists"

2) Your program should create a list named "fnames"

3) Your program should ask your user to enter a first name.

5) Your program should repeat asking your user for additional first names until a total of 10 first names have been entered

6) After a total of 10 names have been asked/entered into your list, ask the user to search for a name

7) Your program should then search the list for that name

8) If the name is found, your program should state the name searched for and return the position in the list. For example:

"Eric was found at position number 5 in the list"

If that name was not found your program should provide a message to that effect to the user

 

═════════════════════

If your position at your table is designated as 'green':

Please write a program to the following specifics. YOU MUST use the names, variables and function names provided:

 

1) Create a program called "lists"

2) Your program should create a list named "cityNames"

3) Your program should ask your user to enter a city name.

5) Your program should repeat asking your user for additional city names until a total of 10 first names have been entered

6) After a total of 10 names have been asked/entered into your list, ask the user to search for a city name

7) Your program should then search the list for that city name

8) If the name is found, your program should state the city name searched for and return the position in the list. For example:

"Boston was found at position number 5 in the list"

If that city name was not found your program should provide a message to that effect to the user

 

If your position at your table is designated as 'red':

Please write a program to the following specifics. YOU MUST use the names, variables and function names provided:

 

1) Create a program called "lists"

2) Your program should create a list named "plantNames"

3) Your program should ask your user to enter a plant name.

5) Your program should repeat asking your user for additional plant names until a total of 10 plant names have been entered

6) After a total of 10 plant names have been asked/entered into your list, ask the user to search for a plant name

7) Your program should then search the list for that plant name

8) If the plant name is found, your program should state the plant name searched for and return the position in the list. For example:

"Roses was found at position number 5 in the list"

If that name was not found your program should provide a message to that effect to the user

If your position at your table is designated as 'orange':

Please write a program to the following specifics. YOU MUST use the names, variables and function names provided:

 

1) Create a program called "lists"

2) Your program should create a list named "animalNames"

3) Your program should ask your user to enter a animal name.

5) Your program should repeat asking your user for additional animal names until a total of 10 animal names have been entered

6) After a total of 10 animal names have been asked/entered into your list, ask the user to search for an animal name

7) Your program should then search the list for that animal name

8) If the name is found, your program should state the animal name searched for and return the position in the list. For example:

"Cat was found at position number 5 in the list"

If that animal name was not found your program should provide a message to that effect to the user